/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package ia_psr.problemas.transportes;

/**
 *
 * @author Rubén Avalos Elvira y Fabiana Celiberti Tapie
 */
import java.util.Comparator;
import ia_psr.graph.Tarea;
public class TareaPorHorarioComparator implements Comparator {
    public int compare(Object a, Object b) {
        if (a instanceof Tarea && b instanceof Tarea) {
            Tarea t1 = (Tarea)a;
            Tarea t2 = (Tarea)b;
            return t1.h.compareTo(t2.h);
        }
        return 0;
    }
}
